package com.xiaomage.view.draw12

import android.support.v7.app.AppCompatActivity
import android.os.Bundle
import android.view.ViewGroup
import android.widget.LinearLayout
import kotlinx.android.synthetic.main.activity_main.*

class MainActivity : AppCompatActivity() {

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_main)
        val myView=MyView(this)
        val params=LinearLayout.LayoutParams(
                LinearLayout.LayoutParams.MATCH_PARENT,
                1000
        )
        myView.layoutParams=params
        ll_zong.addView(myView)
        val xindiantu=Xindiantuview(this)
        xindiantu.layoutParams=params
        ll_zong.addView(xindiantu)
    }
}
